package com.you.springcloud.alibaba.demo.dao.impl;

import com.you.springcloud.alibaba.demo.dao.UserDao;
import com.you.springcloud.alibaba.demo.bo.UserBo;
import com.you.springcloud.alibaba.demo.entity.User;
import com.you.springcloud.alibaba.demo.mapper.UserMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public class UserDaoImpl implements UserDao {

    @Autowired
    private UserMapper userMapper;


    @Override
    public int insertUser(User user) {
        return userMapper.insert(user);
    }

    public List<User> getUserById(String id) {

        return userMapper.getUserById(id);
    }
}
